#define _CRT_SECURE_NO_WARNINGS 1
#include "Tree.h"
void BinaryTest()
{
	BTNode* n1 = ByNode(1);
	BTNode* n2 = ByNode(2);
	BTNode* n3 = ByNode(3);
	BTNode* n4 = ByNode(4);
	BTNode* n5 = ByNode(5);
	BTNode* n6 = ByNode(6);
	BTNode* n7 = ByNode(7);

	n1->left = n2;
	n1->right = n3;
	n2->left = n4;
	n2->right = n5;
	n3->left = n6;
	n3->right = n7;

	//PosOrder(n1);
	BTNode* find = BinaryTreeFind(n1, 2);
	if(find != NULL)
	fprintf(stdout,"%d",find->date);
	BinaryTreeDestroy(n1);
	n1 = NULL;
}

int main()
{
	BinaryTest();
	return 0;
}